package com.wufan.day03;

/**
 * 圆的面积
 * @author SongWufan
 * @date 2021/3/7 15:45
 */
public class CircleArea {
    public static void main(String[] args) {
        Circle c1 = new Circle();
        c1.radius = 2;
        double area = c1.findArea();
        System.out.println(area);
    }
}

class Circle{
    /**
     * 半径
     */
    double radius;


    /**
     * 求圆的面积
     * @return area
     */
    public double findArea(){
        double area = Math.PI * Math.pow(radius,2);
        return area;
    }


}
